const baseURL = 'https://zg.particlesoft.info/frontend/';

const api = ({
  url,
  method = "get",
  data = ""
}) => {
  return new Promise((resolve, reject) => {
    wx.request({
      url: baseURL + url,
      method: method,
      data: data,
      success: res => {
        resolve(res)
      }
    })
  })
}

// 导出
export default api